package com.ghca.myinfo3.system.mapper;

import com.ghca.myinfo3.system.entity.Department;
import com.ghca.myinfo3.system.entity.Permission;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * Created by Administrator on 2016/12/25.
 */
@Mapper
public interface DepartmentMapper {


    @Select("select * from department d where d.parent_id = #{parentId} or d.parent_id is null ")
    public List<Department> selectByParentId(@Param("parentId") Long parentId);
}
